<LayoutTableSmall>
    <!-- 顶部 -->
    <template slot="top"></template>
    <!-- 其他 -->
    <template slot="other"></template>
    <!-- 搜索 -->
    <template slot="search">
        <el-form :inline="true" label-position="left" label-width="80px" :model="mixinTable_tableSearchData">
            <el-form-item>
                <el-input clearable v-model="mixinTable_tableSearchData.name" placeholder="请输入站点名称"
                    @change="mixinTable_searchData" style="width:200px">
                    <el-button slot="append" icon="el-icon-search" @click="mixinTable_searchData()"></el-button>
                </el-input>
            </el-form-item>
            <!-- 到期状态  -->
            <el-form-item label="到期状态:">
                <el-select v-model="mixinTable_tableSearchData.expireStatus" @change="mixinTable_searchData" clearable
                    style="width:100px">
                    <el-option label="正常" value="0"></el-option>
                    <el-option label="过期" value="1"></el-option>
                </el-select>
            </el-form-item>
            <!-- 开启状态  -->
            <el-form-item label="到期状态:">
                <el-select v-model="mixinTable_tableSearchData.closeStatus" @change="mixinTable_searchData" clearable
                    style="width:100px">
                    <el-option label="开启" value="0"></el-option>
                    <el-option label="关闭" value="1"></el-option>
                </el-select>
            </el-form-item>
            <!-- 运营状态  -->
            <el-form-item label="运营状态:">
                <el-select v-model="mixinTable_tableSearchData.status" @change="mixinTable_searchData" clearable
                    style="width:100px">
                    <el-option label="正常" value="0"></el-option>
                    <el-option label="停运" value="1"></el-option>
                </el-select>
            </el-form-item>
        </el-form>
    </template>
    <!-- 功能 -->
    <template slot="function">
        <el-button type="primary" @click="editBoxOpen({type:'add'})">创建站点</el-button>
    </template>
    <!-- 表格 -->
    <template slot="table">

        <el-table v-loading="mixinTable_loading" :data="mixinTable_tableData" border class="tableStyle" :ref="mixinPage_vueName+'TableSmall'" height="100%"
            row-key="id" @selection-change="mixinTable_handleSelectionChangeTableSmall"
            :tree-props="{children: 'children'}">
            <el-table-column type="selection" width="50" align="center"></el-table-column>
            <el-table-column prop="id" label="ID" width="50" align="center">
            </el-table-column>
            <el-table-column prop="name" label="站点名称"></el-table-column>
            <el-table-column prop="mobile" label="管理员"></el-table-column>
            <el-table-column prop="createdTimeStr" label="创建时间" width="160"></el-table-column>
            <el-table-column prop="type"  align="center" label="有效期时间">
                <template slot-scope="scope">{{scope.row.type==2?'无限':scope.row.validityTime}}</template>
            </el-table-column>
            <el-table-column prop="status"  align="center" label="运行状态">
                <template slot-scope="scope"><StateIcon :type="scope.row.status==0?'success':'error'"></StateIcon></template>
            </el-table-column>
            <el-table-column prop="expireStatus"  align="center" label="是否到期">
                <template slot-scope="scope">{{scope.row.expireStatus==0?'未到期':'已到期'}}</template>
            </el-table-column>
            <el-table-column label="操作" width="300" align="center">
                <template slot-scope="scope">
                    <el-button @click="editBoxOpen({type:'copy',id:scope.row.id})">复制</el-button>
                    <el-button @click="toSite(scope.row.id)">跳转站点</el-button>
                    <el-button @click="editBoxOpen({type:'update',id:scope.row.id})">编辑</el-button>
                    <el-button v-if="scope.row.delStatus==0" type="danger" plain
                        @click="confirmPlatformStatus(scope.row,'unable')">关闭</el-button>
                    <el-button v-if="scope.row.delStatus==1" type="success" plain
                        @click="confirmPlatformStatus(scope.row,'enable')">开启</el-button>
                </template>
            </el-table-column>

        </el-table>

    </template>
    <!-- 表格选项 -->
    <template slot="options">
        <el-button :disabled="mixinTable_selectTableData.length<=0" @click="mixinTable_selectTableDeleteData()">
            停用已选</el-button>
        <el-button :disabled="mixinTable_selectTableData.length<=0"
            @click="mixinTable_clearSelectionChangeTableSmall()">取消选择
        </el-button>
    </template>
    <!-- 分页 -->
    <template slot="page">
        <el-pagination class="paginationStyle" v-if="mixinTable_pageData.total>0" background
            @current-change="mixinTable_pagingData($event)" :current-page="mixinTable_pageData.pageNum"
            :page-size.sync="$vFN.Constants.pageSize" layout="total, prev, pager, next,jumper"
            :total.sync="mixinTable_pageData.total">
        </el-pagination>
    </template>
</LayoutTableSmall>